# Python内置函数
from collections import deque
q = deque([1,2,3],4)
print(q)
q.append(1)
print(q)
q.append(2)
print(q)
q.pop()
print(q)
q.append(2)
print(q)
q.popleft()
print(q)